package com.cjr.mq.simple;

import com.cjr.mq.config.QueueConfig;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

@Component
public class ReceiveMsg {

    //接收消息，监听消息队列
    @RabbitListener(queues = QueueConfig.QUEUE )
    public void receive_2(String content) {
        System.out.println("我是消费者a，接收到的信息：" + content);
    }
}
